<?php
class ProjectsController extends Zend_Controller_Action
{
	// 初始化
	function init()
	{
		// 取得数据库指针
		$this->view->action=$this->_getParam('action');
		$this->view->controller=$this->_getParam('controller');
		$this->view->title = '软件教研室';
	}

	// 处理no action异常
	function __call($method, $args)
	{
		if ('Action'==substr($method, -6)) {
			$this->view->action=substr($method, 0, -6);
			$this->view->param=$this->_getAllParams();
			$this->renderScript('error/no-action.php');
		}
		else // 其他异常
			$this->_redirect('/');
	}

	/* 下面是action处理函数: ***************************/

	// 首页
	function indexAction()
	{
		$this->renderScript('error/on-doing.php');
	}

};
?>
